home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Source Code / Libraries / DCLAP 6d / dclap6d / corelib / ncbitime.h < prev    next >
Text File  |  1996-07-05  |  3KB  |  90 lines

  1. /*  ncbitime.h
  2. * ===========================================================================
  3. *
  4. *                            PUBLIC DOMAIN NOTICE                          
  5. *               National Center for Biotechnology Information
  6. *                                                                          
  7. *  This software/database is a "United States Government Work" under the   
  8. *  terms of the United States Copyright Act.  It was written as part of    
  9. *  the author's official duties as a United States Government employee and 
  10. *  thus cannot be copyrighted.  This software/database is freely available 
  11. *  to the public for use. The National Library of Medicine and the U.S.    
  12. *  Government have not placed any restriction on its use or reproduction.  
  13. *                                                                          
  14. *  Although all reasonable efforts have been taken to ensure the accuracy  
  15. *  and reliability of the software and data, the NLM and the U.S.          
  16. *  Government do not and cannot warrant the performance or results that    
  17. *  may be obtained by using this software or data. The NLM and the U.S.    
  18. *  Government disclaim all warranties, express or implied, including       
  19. *  warranties of performance, merchantability or fitness for any particular
  20. *  purpose.                                                                
  21. *                                                                          
  22. *  Please cite the author in any work or product based on this material.   
  23. *
  24. * ===========================================================================
  25. *
  26. * File Name:  ncbitime.h
  27. *
  28. * Author:  Ostell, Kans
  29. *
  30. * Version Creation Date:  1/1/90
  31. *
  32. * $Revision: 2.1 $
  33. *
  34. * File Description:
  35. *   misc portable routines with
  36. *   dates, times, timers
  37. *   prototypes and defines
  38. *
  39. * Modifications:  
  40. * --------------------------------------------------------------------------
  41. * Date     Name        Description of modification
  42. * -------  ----------  -----------------------------------------------------
  43. * 09-19-91 Schuler     Redefined DayTime struct as ASNI struct tm.
  44. * 09-19-91 Schuler     Use ANSI functions for time services instead of
  45. *                       the Macintosh and Windows functions.
  46. * 04-15-93 Schuler     Changed _cdecl to LIBCALL
  47. *
  48. * ==========================================================================
  49. */
  50.  
  51. #ifndef _NCBITIME_
  52. #define _NCBITIME_
  53.  
  54. #ifdef __cplusplus
  55. extern "C" {
  56. #endif
  57.  
  58. #include <time.h>
  59.  
  60. typedef struct tm   Nlm_DayTime, PNTR Nlm_DayTimePtr;
  61.  
  62. #if 0 
  63. /*old version*/
  64. typedef struct daytime {
  65.   Nlm_Int2  year,            /* year - 1900 */
  66.         month,            /* 0-11  January = 0 */
  67.         day,            /* 1-31 */
  68.         wday,            /* 0-6   Sunday = 0 */
  69.         hour,            /* 0-24 */
  70.         min,            /* 0-59 */
  71.         sec;            /* 0-59 */
  72. } Nlm_DayTime, PNTR Nlm_DayTimePtr;
  73. #endif
  74.  
  75. time_t LIBCALL  Nlm_GetSecs PROTO((void));
  76. Nlm_Boolean LIBCALL  Nlm_GetDayTime PROTO((Nlm_DayTimePtr dtp));
  77. Nlm_Boolean LIBCALL  Nlm_DayTimeStr PROTO((Nlm_CharPtr buf, Nlm_Boolean date, Nlm_Boolean time));
  78.  
  79. #define DayTime Nlm_DayTime
  80. #define DayTimePtr Nlm_DayTimePtr
  81. #define GetSecs Nlm_GetSecs
  82. #define GetDayTime Nlm_GetDayTime
  83. #define DayTimeStr Nlm_DayTimeStr
  84.  
  85. #ifdef __cplusplus
  86. }
  87. #endif
  88.  
  89. #endif
  90.